// components/roomCard/roomCard.js
const cloud = require('../../utils/cloudFunction')
const cloud1 = require('../../pages/index/sideBar/management/management')

Component({
    /**
     * Component properties
     * 供外部传值进来使用
     */
    properties: {
        roomId: {
            type: String,
            value: 0
        },
        roomName: {
            type: String,
            value: ''
        },
        devNumber: {
            type: Number,
            value: 0
        },
    },

    /**
     * Component initial data
     */
    data: {

    },

    /**
     * Component methods
     */
    methods: {
        editRoom(e) {
            var that = this
            // setTimeout(function () {
                that.triggerEvent('editRoom')
            // }, 350)
        },
        deleteRoom(e) {
            var that = this
            // setTimeout(function () {
                that.triggerEvent('deleteRoom')
            // }, 350)
            // cloud.roomDelete(this.properties.roomId).then(function name(params) {
            //     cloud.changeStatus()
            // })
        }
    }
})